(global.webpackJsonp = global.webpackJsonp || []).push([ [ "pages/login/login-h5" ], {
    "23b4": function(t, e, o) {
        (function(t) {
            Object.defineProperty(e, "__esModule", {
                value: !0
            }), e.default = void 0;
            var o = {
                data: function() {
                    return {
                        maxMobile: 11,
                        mobile: "",
                        code: "",
                        verification: !0,
                        timer: 60,
                        btnb: "btn btn-square btn-c btn-all"
                    };
                },
                onLoad: function(t) {},
                computed: {
                    rightMobile: function() {
                        var t = {};
                        return this.mobile ? /^1[3456789]{1}\d{9}$/gi.test(this.mobile) ? t.status = !0 : (t.status = !1, 
                        t.msg = "手机号格式不正确") : (t.status = !1, t.msg = "请输入手机号"), t;
                    },
                    sendCodeBtn: function() {
                        var t = "btn btn-g";
                        return this.mobile.length === this.maxMobile && this.rightMobile.status ? t + " btn-b" : t;
                    },
                    regButtonClass: function() {
                        return this.mobile && this.mobile.length === this.maxMobile && this.code ? this.btnb + " btn-blogin" : this.btnb;
                    }
                },
                onShow: function() {
                    var t = this;
                    t.$db.get("userToken"), t.timer = parseInt(t.$db.get("timer")), null != t.timer && t.timer > 0 && (t.countDown(), 
                    t.verification = !1);
                },
                methods: {
                    sendCode: function() {
                        var t = this;
                        this.rightMobile.status ? (this.$common.loadToShow("发送中..."), setTimeout(function() {
                            t.$common.loadToHide();
                            var e = {
                                mobile: t.mobile
                            };
                            t.$api.smsApi(e, function(e) {
                                "1" == e.code ? (t.timer = 60, t.verification = !1, t.$common.successToShow(e.msg), 
                                t.countDown()) : t.$common.errorToShow(e.msg);
                            });
                        }, 1e3)) : this.$common.errorToShow(this.rightMobile.msg);
                    },
                    countDown: function() {
                        var e = this, o = setInterval(function() {
                            e.timer--, t.setStorage({
                                key: "timer",
                                data: e.timer,
                                success: function() {}
                            }), e.timer <= 0 && (e.verification = !0, clearInterval(o));
                        }, 1e3);
                    },
                    toBind: function() {
                        var t = this;
                        if ("" == this.mobile) return this.$common.errorToShow("请输入手机号码"), !1;
                        if ("" == this.code) return this.$common.errorToShow("请输入验证码"), !1;
                        var e = {
                            mobile: this.mobile,
                            code: this.code,
                            invite_id: this.$db.get("shareId") || "",
                            is_business: this.$db.get("is_business") || "",
                            thirduserid: this.$db.get("thirduserid") || "",
                            source: this.$db.get("source") || "6"
                        };
                        this.$api.bindMobileApi(e, function(e) {
                            "1" != e.code ? t.$common.errorToShow(e.msg) : (t.$db.clear(), t.$db.set("userToken", e.data.token), 
                            t.$db.set("userId", e.data.user_id), t.$db.set("mobile", e.data.mobile), t.$store.state.showjtk = e.data.showpf, 
                            t.$api.getUserInfoApi({
                                user_id: t.$db.get("userId")
                            }, function(e) {
                                if ("1" == e.code) {
                                    var o = e.data;
                                    t.$db.set("userInfo", o), t.redirectHandler();
                                } else t.$common.errorToShow(e.msg);
                            }));
                        });
                    },
                    redirectHandler: function() {
                        var e = this;
                        this.$common.successToShow("登录成功!", function() {
                            e.$db.set("timer", 0);
                            var o = e.$db.get("redirectPage");
                            o ? (e.$db.del("redirectPage"), e.$common.redirectTo(o)) : t.reLaunch({
                                url: "/pages/member/index/index"
                            });
                        });
                    }
                }
            };
            e.default = o;
        }).call(this, o("543d").default);
    },
    3288: function(t, e, o) {},
    "473b": function(t, e, o) {
        o.r(e);
        var i = o("23b4"), n = o.n(i);
        for (var r in i) "default" !== r && function(t) {
            o.d(e, t, function() {
                return i[t];
            });
        }(r);
        e.default = n.a;
    },
    "4d0f": function(t, e, o) {
        o.d(e, "b", function() {
            return i;
        }), o.d(e, "c", function() {
            return n;
        }), o.d(e, "a", function() {});
        var i = function() {
            this.$createElement, this._self._c;
        }, n = [];
    },
    5216: function(t, e, o) {
        o.r(e);
        var i = o("4d0f"), n = o("473b");
        for (var r in n) "default" !== r && function(t) {
            o.d(e, t, function() {
                return n[t];
            });
        }(r);
        o("925a");
        var s = o("f0c5"), a = Object(s.a)(n.default, i.b, i.c, !1, null, "6c5a2eff", null, !1, i.a, void 0);
        e.default = a.exports;
    },
    5604: function(t, e, o) {
        (function(t) {
            o("98af"), i(o("66fd"));
            var e = i(o("5216"));
            function i(t) {
                return t && t.__esModule ? t : {
                    default: t
                };
            }
            wx.__webpack_require_UNI_MP_PLUGIN__ = o, t(e.default);
        }).call(this, o("543d").createPage);
    },
    "925a": function(t, e, o) {
        var i = o("3288");
        o.n(i).a;
    }
}, [ [ "5604", "common/runtime", "common/vendor" ] ] ]);